package bookstore.manager;

import bookstore.bound.auth.EnrollForm;
import bookstore.bound.auth.UsernameForm;
import bookstore.bound.user.UserDisp;
import bookstore.model.UserProfile;

import javax.servlet.http.HttpSession;
import java.util.Map;
import java.util.Set;

public interface UserManager {

    // Create

    Map enroll(HttpSession session, EnrollForm form);

    Map checkUsername(String username);

    Map getUserProfile(HttpSession session);

    // Retrieve
    Set<UserDisp> getAllUsers();

    // Update
    Map setUsername(HttpSession session, UsernameForm form);

    Map updateProfile(HttpSession session, UserProfile userProfile);

    Map updateTel(Long id, String tel);

    Map updateActivate(Long id, boolean activate);

    Map updateStaff(Long id, boolean staff);

    Map updateAvailable(Long id, boolean available);

    // Delete
    Map delete(Long id);


}
